#!/usr/bin/perl

use warnings;
use strict;

open (SAMPLE, "sample.file") or die $!;

foreach (<SAMPLE>) {
    if ( $_ =~ /(.*Gortz.*):.*:(.*):.*:.*/) {
        printf "%s lives in %s.\n", $1, $2;
    }
}

close SAMPLE;
